

jQuery(document).ready(function() {
	
	$('.stud_in_select').click(function(){
		$('.stud_in_select option:selected').appendTo('.stud_out_select');
		$('.stud_out_select option:selected').removeAttr('selected');
	});
	
	$('.stud_out_select').click(function(){
		$('.stud_out_select option:selected').appendTo('.stud_in_select');
		$('.stud_in_select option:selected').removeAttr('selected');
	});
	
	$('form').submit(function(){
		alert("submit");
		$('.stud_in_select option').addAttr('selected');	
	});
	
});

	function select_all(){
		$('.stud_in_select option').attr('selected', 'selected');	
		document.forms[0].submit();
	}